package com.ewzj.bigdata.mvp.model.entity.resbean;

import android.os.Parcel;
import android.os.Parcelable;

import java.util.List;

/**
 * Author:zhangjing
 * Time:2018/3/14  下午2:09
 * Name: this is CollectBean
 * Email:zhangjingworkmol@163.com
 */

public class CollectBean implements Parcelable {

    /**
     * id : 1233463482355
     * title : 分组2
     * thumb : ["http://img01.taopic.com/180221/318763-1P221105A479.jpg"]
     * num : 18
     * time : 2018-01-09
     */

    private long id;
    private String title;
    private int num;
    private String time;
    private String thumb;
    private Boolean isSelected=false;

    public Boolean getSelected() {
        return isSelected;
    }

    public void setSelected(Boolean selected) {
        isSelected = selected;
    }


    public long getId() {
        return id;
    }

    public void setId(long id) {
        this.id = id;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public int getNum() {
        return num;
    }

    public void setNum(int num) {
        this.num = num;
    }

    public String getTime() {
        return time;
    }

    public void setTime(String time) {
        this.time = time;
    }

    public String getThumb() {
        return thumb;
    }

    public void setThumb(String thumb) {
        this.thumb = thumb;
    }

    public CollectBean() {
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeLong(this.id);
        dest.writeString(this.title);
        dest.writeInt(this.num);
        dest.writeString(this.time);
        dest.writeString(this.thumb);
        dest.writeValue(this.isSelected);
    }

    protected CollectBean(Parcel in) {
        this.id = in.readLong();
        this.title = in.readString();
        this.num = in.readInt();
        this.time = in.readString();
        this.thumb = in.readString();
        this.isSelected = (Boolean) in.readValue(Boolean.class.getClassLoader());
    }

    public static final Creator<CollectBean> CREATOR = new Creator<CollectBean>() {
        @Override
        public CollectBean createFromParcel(Parcel source) {
            return new CollectBean(source);
        }

        @Override
        public CollectBean[] newArray(int size) {
            return new CollectBean[size];
        }
    };
}
